<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>documentName</title>
  </head>

  <body>
    <canvas id="myCanvas" width="600" height="300">
      <p>您的浏览器不支持 canvas!</p>
    </canvas>

    <script src="/node_modules/jquery/dist/jquery.min.js"></script>
    <script src="/node_modules/jcanvas/dist/jcanvas.js"></script>
    <script>
      var $myCanvas = $('#myCanvas')

      $myCanvas.drawImage({
        // 设置图像源（本地，url, canvas等）
        source: 'https://s3-us-west-2.amazonaws.com/s.cdpn.io/123941/cat.jpg',
        x: 250,
        y: 100,
        fromCenter: false, // 同 矩形的属性作用
        shadowColor: '#222', // 阴影颜色
        shadowBlur: 3, // 阴影模糊度
        rotate: 40, // 旋转角度
      })
    </script>
  </body>
</html>
